Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Function |unwrap_or

std/ops/option::|unwrap_or


Usage

|unwrap_or<T>(option, default)

Generics

◻ T (any)

Parameters

↳ option: Option<T>
↳ default: T

Return

T


Return the contained value if option is some, or default if it is none.